(function (factory) {
    if (typeof module === "object" && typeof module.exports === "object") {
        var v = factory(require, exports);
        if (v !== undefined) module.exports = v;
    }
    else if (typeof define === "function" && define.amd) {
        define(["require", "exports", "json!../websiteConfig"], factory);
    }
})(function (require, exports) {
    "use strict";
    Object.defineProperty(exports, "__esModule", { value: true });
    const websiteConfig_1 = require("json!../websiteConfig");
    (function () {
        let node_modules = "/node_modules";
        let lib = "assert/lib";
        requirejs.config({
            context: websiteConfig_1.contextName,
            shim: {
                fetch: {
                    exports: 'fetch'
                },
                controls: {
                    deps: ['react-dom', 'react']
                },
                mobileControls: {
                    exports: 'controls',
                    deps: ['hammer', 'bezier-easing', 'react']
                },
                userServices: {
                    exports: 'userServices'
                },
            },
            baseUrl: './',
            paths: {
                css: `${lib}/css`,
                less: `${lib}/require-less-0.1.5/less`,
                lessc: `${lib}/require-less-0.1.5/lessc`,
                normalize: `${lib}/require-less-0.1.5/normalize`,
                text: `${lib}/text`,
                "js-md5": `${node_modules}/js-md5/src/md5`,
                "react": `${node_modules}/react/umd/react.development`,
                "react-dom": `${node_modules}/react-dom/umd/react-dom.development`,
                "maishu-wuzhui": `${node_modules}/maishu-wuzhui/dist/index`,
                'maishu-chitu': `${node_modules}/maishu-chitu/dist/index`,
                "maishu-dilu": `${node_modules}/maishu-dilu/dist/index`,
                "maishu-chitu-react": `${node_modules}/maishu-chitu-react/dist/index`,
                "maishu-wuzhui-helper": `${node_modules}/maishu-wuzhui-helper/dist/index`,
                "maishu-chitu-service": `${node_modules}/maishu-chitu-service/dist/index`,
                "maishu-jueying": `${node_modules}/maishu-jueying/dist/index`,
                "maishu-ui-toolkit": `${node_modules}/maishu-ui-toolkit/dist/index`,
                "maishu-services-sdk": `${node_modules}/maishu-services-sdk/dist/index`,
                "maishu-haoyi-shop": `${node_modules}/maishu-haoyi-shop/`,
                "modules": "mobile/modules",
            }
        });
        // requirejs(["css!lib/Font-Awesome-3.2.1/css/font-awesome"]);
        requirejs({ context: websiteConfig_1.contextName }, ['mobile/user-application'], function (appExports) {
            let app = appExports.app;
            app.run();
        });
    })();
});
